#include "broker.h"

#include <stdio.h>
#include <stdint.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>

struct bcshm_t shm;

void eventer(){
    
  flight_task_t ft = {.hight = 20, .start_time = 0, .hang_time = 10};
  bcshm_write(SHM_FLIGHT_TASK, &shm, &ft);
  
  while(1){
    FCACTION_t fc_act;

    scanf("%d", &fc_act);
    bcshm_write(SHM_FCACTION, &shm, &fc_act);
  }
}

int main(int argc, char* argv[]) {

  bcshm_open(&shm);
  
  eventer();
  
  bcshm_close(&shm);

  return 0;
}
